#include "assert.h"


void
func1() {
	assert(0); // call macro
}

void 
func2() {
	func1();
}

void
func3() {
	(assert)(0); // call function
}

int
main() {
TRY
	func2();
EXCEPT(ex_assert_failed)
	printf("assert macro fail, file:%s, line:%d\n", EXCEPT_FILE, EXCEPT_LINE);
ELSE
	printf("default for except");
END_TRY

TRY
	func3();
EXCEPT(ex_assert_failed)
	printf("assert function fail, file:%s, line:%d\n", EXCEPT_FILE, EXCEPT_LINE);
ELSE
	printf("default for except");
END_TRY
	printf("assert test pass\n");
	return 0;
}
